projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1af7410
)
* src/floatfns.c (Fftruncate): Simplify via emacs_trunc.
author
Paul Eggert
<eggert@cs.ucla.edu>
Sun, 5 Mar 2017 07:14:51 +0000
(23:14 -0800)
committer
Paul Eggert
<eggert@cs.ucla.edu>
Sun, 5 Mar 2017 07:18:38 +0000
(23:18 -0800)
src/floatfns.c
patch
|
blob
|
history
diff --git
a/src/floatfns.c
b/src/floatfns.c
index 94da22a3ba7fb8768e548d12c47c20f97cbf0a73..9ae810669effcf021b81e445771e3d85c0d1e930 100644
(file)
--- a/
src/floatfns.c
+++ b/
src/floatfns.c
@@
-534,10
+534,7
@@
Rounds the value toward zero. */)
(Lisp_Object arg)
{
double d = extract_float (arg);
- if (d >= 0.0)
- d = floor (d);
- else
- d = ceil (d);
+ d = emacs_trunc (d);
return make_float (d);
}
\f